package com.pablosz.worm.components;

import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;

import com.pablosz.worm.Lifecicle;
import com.pablosz.worm.LifecicleComponent;
import com.pablosz.worm.util.LifecicleComponents;

public class Score extends LifecicleComponent
{
	private double points=0;
	private transient Paint paint;
	
	public Score()
	{
		paint = new Paint();
		paint.setColor(Color.GREEN);
	}
	
	public void addPoints(double p)
	{
		points+=p;
	}
	
	public double getPoints()
	{
		return points;
	}

	@Override
	public void print(Canvas canvas)
	{
	}

	@Override
	public void onTouch(Lifecicle lf,LifecicleComponents components,long x,long y)
	{
	}

	@Override
	public void init(Lifecicle lf,LifecicleComponents components,long width,long height)
	{
		points = 0;
	}

	@Override
	public void process(Lifecicle lf,LifecicleComponents components,long width,long height)
	{
	}

	@Override
	public boolean finish(Lifecicle lf,LifecicleComponents components,long width,long height)
	{
		return true;
	}
	
}
